let str='hello world'
//console.log(str.charAt(1));
//console.log(atr[1]);
//console.log(str+'hi');

let arr=str.split(' ')//将字符串转换为数组
arr.splice(1,0,'hi')
console.log(arr.join(' '));


